Field of the Invention
The present invention relates to a method for controlling a three-dimensional measuring apparatus that can measure a target object three-dimensionally.
Description of the Related Art
Various types of methods are conventionally proposed to measure a target object (e.g., a component of an industrial product) three-dimensionally. One of the conventional methods is a highly accurate and stable measuring method that includes projecting a predetermined projection pattern (e.g., a striped pattern or a lattice pattern) on a measurement target object and capturing an image of the measurement target object. The method further includes obtaining a correspondence relationship between each image position (i.e., a pixel) of the captured image and a corresponding striped position of the projection pattern, calculating the height of the measurement target object based on the triangulation, and measuring a three-dimensional shape of the measurement target object.
In the above-mentioned three-dimensional measurement method, multiple reflections may occur if the measurement target object (e.g., a metallic member) is glossy. More specifically, a projection pattern projected on one surface of the measurement target object may reflect on another surface of the measurement target object (may cause reflections multiple times) depending on the shape of the measurement target object. The reflection of light is referred to as primary reflection if it first reflects on a surface of the measurement target object. The reflection of light is referred to as secondary reflection if it sequentially reflects on two surfaces of the measurement target object. Further, the reflection of light is referred to as tertiary reflection if it sequentially reflects three times on the measurement target object. The above-mentioned secondary and higher-order reflections can be collectively referred to as multiple reflections. The multiple reflections can be also referred to as interreflection because reflections repetitively occur on different surfaces of the same measurement target object. If multiple reflections occur, a glare appears although it is not originally present on the measurement target object. If such a defective image is used in the three-dimensional measurement processing, the measurement accuracy may deteriorate due to a noise component caused by the glare.
To eliminate the glare, for example, as discussed in Japanese Patent Application Laid-Open No. 2008-309551, it is conventionally proposed to dim or quench a part of the projection pattern that causes multiple reflections on surfaces of an inspected object. More specifically, it is conventionally known to project two types of different projection patterns and obtain a three-dimensional shape based on each of these patterns. Then, if there is a significant difference between two three-dimensional measurement results in a target area, it can be determined that multiple reflections have occurred in this area. Further, the conventional method includes performing ray tracing to detect a surface on which multiple reflections occur, quenching a projection pattern portion that corresponds to the detected surface, and correcting the three-dimensional measurement result based on a captured image obtainable by projecting a newly quenched projection pattern on a measurement target object.
According to the method discussed in Japanese Patent Application Laid-Open No. 2008-309551, it is necessary to project the projection pattern multiple times to find out the projection pattern portion that causes multiple reflections although it is useful to dim or quench a part of the projection pattern. More specifically, information about the measurement target object is not available when the projection pattern is generated. Therefore, in an initial stage, the required number of pattern projections cannot be identified. Further, confirming whether an optimum projection pattern has been projected is difficult. Thus, it is required to perform determination at appropriate timing while continuously repeating the projection and imaging operations.